package id.net.iconpln.bb.server;

import id.net.iconpln.bb.client.service.TransportRPCService;
import id.net.iconpln.bb.server.service.GudangService;
import id.net.iconpln.bb.server.service.TransportService;

import java.util.ArrayList;
import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import com.google.gwt.user.server.rpc.RemoteServiceServlet;

@Repository
public class TransportRPCServiceImpl  extends RemoteServiceServlet implements TransportRPCService{
	@Autowired private TransportService transportService;
	@Autowired private GudangService gudangService;
	
	@Override
	public List<Map> getListPengendalian(String kode, Map map) {	
		List<Map> lMap = transportService.GetListPengendalian(kode, map);
		return lMap;
	}

	@Override
	public List<Map> insertPengirimanBB(String kode, Map map) {
		return  transportService.insertPengirimanBB(kode, map);
	}

	@Override
	public List<Map> getListPengiriman(String kode, Map map) {
		// TODO Auto-generated method stub
		return transportService.getListPengiriman(kode, map);
	}
	
	@Override
	public List<Map> insertPengendalianBB(String kode, Map map) {
		List<Map> lMap = new ArrayList<Map>();
		lMap =  transportService.insertPengendalianBB(kode, map);
		return  lMap;
	}

	@Override
	public List<Map> insertGudangBB(String kode, Map map) {
		return gudangService.insertGudangBB(kode, map);		 
	}
	
	@Override
	public List<Map> getListPemakaianBB(String kode, Map map) {
		return gudangService.getListPemakaian(kode, map);		 
	}
	
	@Override
	public List<Map> getNotulenRakor(String kode, Map map) {
		return transportService.getNotulenRakor(kode, map);
	}
	
}
